package com.finance.report.service;

import com.finance.framework.lang.Page;
import com.finance.framework.lang.PageResultBO;
import com.finance.report.bean.pojo.NoCalculationInfo;
import com.finance.report.dao.NoCalculationMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Author: gly
 * @Date: Created in 2017-08-22
 */
@Service
public class NoCalculationService implements INoCalculationService {

    @Autowired
    private NoCalculationMapper noCalculationMapper;

    @Override
    public PageResultBO<NoCalculationInfo> listByPage(Page page) {
        PageResultBO<NoCalculationInfo> pageResultBO=new PageResultBO<NoCalculationInfo>();
        List<NoCalculationInfo> list=noCalculationMapper.listByPage(page);
        pageResultBO.setTotalRecord(page.getTotalRecord());
        pageResultBO.setPageSize(page.getPageSize());
        pageResultBO.setPageNo(page.getPageNo());
        pageResultBO.setDataList(list);
        return pageResultBO;
    }
}
